package com.wsm.springcloud_compose.compose_user_consumer_feign.service;

import com.wsm.springcloud_compose.compose_user_bean.response.SysUsersResponse;
import com.wsm.springcloud_compose.compose_user_consumer_feign.service.hystrix.UserServiceHystrix;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @name: AdminService
 * @Author: wangshimin
 * @Date: 2019-09-01  17:30
 * @Description:
 */
@FeignClient(value = "compose-user-produce", fallback = UserServiceHystrix.class)
public interface UserService {

    @RequestMapping(value = "/login", method = RequestMethod.GET)
    SysUsersResponse login(@RequestParam(value = "userName") String userName);

    /*@RequestMapping(value = "/getRolesById", method = RequestMethod.GET)
    List<SysRoles> getRolesById(long id);

    @RequestMapping(value = "/getPermissionsById", method = RequestMethod.GET)
    List<SysPermissions> getPermissionsById(long id);*/
}
